package acm.pta3;

import java.io.*;
import java.util.PriorityQueue;
import java.util.Scanner;

public class T11 {
    public static void main(String[] args) throws IOException {
        BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
        String[] s = in.readLine().split(" ");
        int n = Integer.parseInt(s[0]);
        int k=Integer.parseInt(s[1]);
        int m=Integer.parseInt(s[2]);
        PriorityQueue<Double> queue=new PriorityQueue<>();
        while (n-- > 0) {
            int max=Integer.MIN_VALUE;
            int min=Integer.MAX_VALUE;
            double res=0;
            String[] num = in.readLine().split(" ");
            for (String s1 : num) {
                int curr = Integer.parseInt(s1);
                max=Math.max(curr,max);
                min=Math.min(curr,min);
                res+=curr;
            }
            res-=max+min;
            if (queue.size()<m){
                queue.add(res);
                continue;
            }
            if (queue.peek()<res){
                queue.poll();
                queue.add(res);
            }
        }
        StringBuilder str=new StringBuilder();
        while (m-- > 0) {
            str.append(String.format("%.3f ",queue.poll()/(k-2)));
        }
        System.out.println(str.substring(0,str.length()-1));
    }
}
